package com.mojo.io.stream;

import java.io.File;
import java.io.FileOutputStream;
import java.io.IOException;

/**
 * 文件输出流
 *
 * @author <a href="mailto:mojo_jj@163.com">Mojo</a>
 */
public class FileOutputStream01 {
    public static void main(String[] args) throws IOException {
        File file = new File("e:\\a.txt");
        FileOutputStream outputStream = new FileOutputStream(file);
        String s = "中文a1111";
        outputStream.write(s.getBytes());
        //写入一个字节ASCII码
        //writeInt(outputStream);
        writeByte(outputStream);
        outputStream.close();
    }

    private static void writeByte(FileOutputStream outputStream) {

    }

    private static void writeInt(FileOutputStream outputStream) throws IOException {
        outputStream.write(1616316161);
    }
}
